package com.ydgk.dao;

import com.ydgk.bean.Logistics;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

import java.util.List;

public interface LogisticsMapper {
    @Insert("insert into logistics values(#{lid},#{lnum},#{ltime},#{o_oid},#{e_eid})")
    void insert(Logistics logistics);

    @Select("select * from logistics where o_oid = #{oid}")
    Logistics findByOid(Integer oid);

    @Delete("delete from logistics where o_oid = #{oid}")
    void deleteByOid(Integer oid);

    @Update("update logistics set lnum = #{lnum}, ltime = #{ltime} where lid = #{lid}")
    void updateById(Logistics logistics);
}
